<?php

import('AdvModel');
class FriendModel extends AdvModel
{
  public function checkFriend($fuid,$mid){
        $map["uid"]  = $fuid;
        $map["fuid"] = $mid;
        $map['status'] = 0;
        $result = $this->where($map)->field('count(1) as count')->find();
        return $result['count'];
    }

}
?>